package com.hgg.domain;

import lombok.Data;
import org.springframework.stereotype.Component;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import java.util.Objects;

/**
 * @author 
 */
@Component

public class TProduct implements Serializable {
    private Integer productid;

    /**
     * 淘宝商品Id
     */
    private String itemid;

    /**
     * 分类Id
     */
    private String categoryid;

    /**
     * 商品名称
     */
    private String producttitle;

    /**
     * 图片地址JSON
     */
    private String smallimages;

    /**
     * 封面图
     */
    private String coverpic;

    /**
     * 售价
     */
    private Double marketprice;

    /**
     * 折后售价
     */
    private Double finalprice;

    /**
     * 店铺名称
     */
    private String shoptitle;

    /**
     * 30天销量
     */
    private Integer volume;

    /**
     * 宝贝地址
     */
    private String itemurl;

    /**
     * 店铺dsr评分
     */
    private Integer dsr;

    /**
     * 宝贝所在地
     */
    private String provcity;

    /**
     * 商家Id
     */
    private String sellerid;

    /**
     * 店铺类型 0淘宝1天猫
     */
    private Integer usertype;

    /**
     * 优惠券门槛金额
     */
    private String couponstartfee;

    /**
     * 优惠券剩余量
     */
    private Integer couponremaincount;

    /**
     * 优惠券总量
     */
    private Integer coupontotalcount;

    /**
     * 优惠券开始时间
     */
    private Date couponstarttime;

    /**
     * 优惠券结束时间
     */
    private Date couponendtime;

    /**
     * 优惠券金额
     */
    private Double couponamount;

    /**
     * 记录创建时间
     */
    private Date createtime;

    /**
     * 记录最后更新时间
     */
    private Date updatetime;

    private static final long serialVersionUID = 1L;

    public Integer getProductid() {
        return productid;
    }

    public void setProductid(Integer productid) {
        this.productid = productid;
    }



    public String getCategoryid() {
        return categoryid;
    }

    public void setCategoryid(String categoryid) {
        this.categoryid = categoryid;
    }

    public String getProducttitle() {
        return producttitle;
    }

    public void setProducttitle(String producttitle) {
        this.producttitle = producttitle;
    }

    public String getSmallimages() {
        return smallimages;
    }

    public void setSmallimages(String smallimages) {
        this.smallimages = smallimages;
    }

    public String getCoverpic() {
        return coverpic;
    }

    public void setCoverpic(String coverpic) {
        this.coverpic = coverpic;
    }

    public Double getMarketprice() {
        return marketprice;
    }

    public void setMarketprice(Double marketprice) {
        this.marketprice = marketprice;
    }

    public Double getFinalprice() {
        return finalprice;
    }

    public void setFinalprice(Double finalprice) {
        this.finalprice = finalprice;
    }

    public String getShoptitle() {
        return shoptitle;
    }

    public void setShoptitle(String shoptitle) {
        this.shoptitle = shoptitle;
    }

    public Integer getVolume() {
        return volume;
    }

    public void setVolume(Integer volume) {
        this.volume = volume;
    }

    public String getItemurl() {
        return itemurl;
    }

    public void setItemurl(String itemurl) {
        this.itemurl = itemurl;
    }

    public Integer getDsr() {
        return dsr;
    }

    public void setDsr(Integer dsr) {
        this.dsr = dsr;
    }

    public String getProvcity() {
        return provcity;
    }

    public void setProvcity(String provcity) {
        this.provcity = provcity;
    }

    public String getItemid() {
        return itemid;
    }

    public void setItemid(String itemid) {
        this.itemid = itemid;
    }

    public String getSellerid() {
        return sellerid;
    }

    public void setSellerid(String sellerid) {
        this.sellerid = sellerid;
    }

    public Integer getUsertype() {
        return usertype;
    }

    public void setUsertype(Integer usertype) {
        this.usertype = usertype;
    }

    public String getCouponstartfee() {
        return couponstartfee;
    }

    public void setCouponstartfee(String couponstartfee) {
        this.couponstartfee = couponstartfee;
    }

    public Integer getCouponremaincount() {
        return couponremaincount;
    }

    public void setCouponremaincount(Integer couponremaincount) {
        this.couponremaincount = couponremaincount;
    }

    public Integer getCoupontotalcount() {
        return coupontotalcount;
    }

    public void setCoupontotalcount(Integer coupontotalcount) {
        this.coupontotalcount = coupontotalcount;
    }

    public Date getCouponstarttime() {
        return couponstarttime;
    }

    public void setCouponstarttime(Date couponstarttime) {
        this.couponstarttime = couponstarttime;
    }

    public Date getCouponendtime() {
        return couponendtime;
    }

    public void setCouponendtime(Date couponendtime) {
        this.couponendtime = couponendtime;
    }

    public Double getCouponamount() {
        return couponamount;
    }

    public void setCouponamount(Double couponamount) {
        this.couponamount = couponamount;
    }

    public Date getCreatetime() {
        return createtime;
    }

    public void setCreatetime(Date createtime) {
        this.createtime = createtime;
    }

    public Date getUpdatetime() {
        return updatetime;
    }

    public void setUpdatetime(Date updatetime) {
        this.updatetime = updatetime;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        TProduct tProduct = (TProduct) o;
        return Objects.equals(productid, tProduct.productid) &&
                Objects.equals(itemid, tProduct.itemid) &&
                Objects.equals(categoryid, tProduct.categoryid) &&
                Objects.equals(producttitle, tProduct.producttitle) &&
                Objects.equals(smallimages, tProduct.smallimages) &&
                Objects.equals(coverpic, tProduct.coverpic) &&
                Objects.equals(marketprice, tProduct.marketprice) &&
                Objects.equals(finalprice, tProduct.finalprice) &&
                Objects.equals(shoptitle, tProduct.shoptitle) &&
                Objects.equals(volume, tProduct.volume) &&
                Objects.equals(itemurl, tProduct.itemurl) &&
                Objects.equals(dsr, tProduct.dsr) &&
                Objects.equals(provcity, tProduct.provcity) &&
                Objects.equals(sellerid, tProduct.sellerid) &&
                Objects.equals(usertype, tProduct.usertype) &&
                Objects.equals(couponstartfee, tProduct.couponstartfee) &&
                Objects.equals(couponremaincount, tProduct.couponremaincount) &&
                Objects.equals(coupontotalcount, tProduct.coupontotalcount) &&
                Objects.equals(couponstarttime, tProduct.couponstarttime) &&
                Objects.equals(couponendtime, tProduct.couponendtime) &&
                Objects.equals(couponamount, tProduct.couponamount) &&
                Objects.equals(createtime, tProduct.createtime) &&
                Objects.equals(updatetime, tProduct.updatetime);
    }

    @Override
    public int hashCode() {

        return Objects.hash(productid, itemid, categoryid, producttitle, smallimages, coverpic, marketprice, finalprice, shoptitle, volume, itemurl, dsr, provcity, sellerid, usertype, couponstartfee, couponremaincount, coupontotalcount, couponstarttime, couponendtime, couponamount, createtime, updatetime);
    }

    @Override
    public String toString() {
        return "TProduct{" +
                "productid=" + productid +
                ", itemid=" + itemid +
                ", categoryid='" + categoryid + '\'' +
                ", producttitle='" + producttitle + '\'' +
                ", smallimages='" + smallimages + '\'' +
                ", coverpic='" + coverpic + '\'' +
                ", marketprice=" + marketprice +
                ", finalprice=" + finalprice +
                ", shoptitle='" + shoptitle + '\'' +
                ", volume=" + volume +
                ", itemurl='" + itemurl + '\'' +
                ", dsr=" + dsr +
                ", provcity='" + provcity + '\'' +
                ", sellerid='" + sellerid + '\'' +
                ", usertype=" + usertype +
                ", couponstartfee='" + couponstartfee + '\'' +
                ", couponremaincount=" + couponremaincount +
                ", coupontotalcount=" + coupontotalcount +
                ", couponstarttime=" + couponstarttime +
                ", couponendtime=" + couponendtime +
                ", couponamount=" + couponamount +
                ", createtime=" + createtime +
                ", updatetime=" + updatetime +
                '}';
    }
}